//
//  AnalysisViewController.m
//  UEAssistant
//
//  Created by mac on 2017/8/30.
//  Copyright © 2017年 youyixinxi. All rights reserved.
//

#import "AnalysisViewController.h"

@interface AnalysisViewController ()<UITableViewDelegate,UITableViewDataSource>

@property (nonatomic, strong) UILabel                                       *titleL;
@property (nonatomic, strong) UITableView                                   *tableView;
@property (nonatomic, strong) UIButton                                      *sureButton;

@end

@implementation AnalysisViewController

- (void)viewWillAppear:(BOOL)animated{
    
    [_titleL setHidden:NO];
}

- (void)viewWillDisappear:(BOOL)animated{
    
    [_titleL setHidden:YES];
}

- (void)viewDidLoad {
    [super viewDidLoad];
    [self initlizeDataSource];
    [self initlizeUserface];
}

- (void)initlizeDataSource{

    
}

- (void)initlizeUserface{

    self.view.backgroundColor = [UIColor whiteColor];
    _titleL = [[UILabel alloc]initWithFrame:CGRectMake(0, 0, 200, 20)];
    _titleL.center = CGPointMake(self.view.center.x, 20);
    _titleL.backgroundColor = [UIColor clearColor];
    _titleL.text = @"上传设置";
    _titleL.textAlignment = NSTextAlignmentCenter;
    _titleL.textColor = [UIColor whiteColor];
    [self.navigationController.navigationBar addSubview:_titleL];
    [self.view addSubview:self.tableView];
    [self.view addSubview:self.sureButton];

}

#pragma mark -- UITableViewDataSource

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    
    return 0;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
    UITableViewCell *testCell = [tableView dequeueReusableCellWithIdentifier:@"" forIndexPath:indexPath];
    return testCell;
}

#pragma mark -- getter
- (UITableView *)tableView{
    
    if (!_tableView) {
        _tableView = [[UITableView alloc]initWithFrame:CGRectMake(0, 0, Screen_Width, Screen_Height) style:UITableViewStyleGrouped];
        [_tableView registerClass:[UITableViewCell class] forCellReuseIdentifier:@""];
        _tableView.backgroundColor = RGB(250, 250, 250, 1);
        _tableView.dataSource = self;
        _tableView.delegate = self;
        _tableView.separatorColor = RGB(241, 241, 241, 1);
        _tableView.rowHeight = 50*Radio;
    }
    return _tableView;
}

- (UIButton *)sureButton{
    
    if (!_sureButton) {
        
        _sureButton = [UIButton buttonWithType:UIButtonTypeSystem];
        _sureButton.frame = CGRectMake(0, Screen_Height - 50*Radio, Screen_Width, 50*Radio);
        _sureButton.backgroundColor = RGB(57, 186, 241, 1);
        [_sureButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
        [_sureButton setTitle:@"完成" forState:UIControlStateNormal];
//        [_sureButton addTarget:self action:@selector(SureButtonCliced) forControlEvents:UIControlEventTouchUpInside];
        _sureButton.titleLabel.font = [UIFont systemFontOfSize:FLEXIBLE(18)];
    }
    return _sureButton;
}


@end
